using System;
using System.Runtime.InteropServices;
namespace BMC.ARSystem
{
	[ClassInterface, Guid("98b452ea-15a2-4833-b68f-1f31309b5a88"), ProgId("BMC.ARSystem.ByteList")]
	public class ByteList
	{
		[Guid("4c26d44c-e085-49d2-a1d0-604dd5779ae7")]
		public enum ByteListType
		{
			SelfDefined,
			Win30Bitmap,
			JPEG,
			TIFF,
			TARGA,
			PCX,
			LocalizedFile,
			AuthenticationString,
			FunctionPointer
		}
		private int _type;
		private byte[] _content;
		public ByteList.ByteListType Type
		{
			get
			{
				return (ByteList.ByteListType)this._type;
			}
			set
			{
				this._type = (int)value;
			}
		}
		public byte[] Content
		{
			get
			{
				return this._content;
			}
			set
			{
				this._content = value;
			}
		}
		public ByteList()
		{
		}
		internal ByteList(object[] rawData, Server server)
		{
			int[] indexSpec = new int[1];
			this.Type = (ByteList.ByteListType)Convert.ToInt32(Util.GetAt(rawData, indexSpec));
			this.Content = (byte[])Util.GetAt(rawData, new int[]
			{
				2
			});
		}
		internal static ByteList createInstance(object[] rawData, Server server)
		{
			return new ByteList(rawData, server);
		}
		internal static object ToVariant(object given, Server server)
		{
			ByteList byteList = given as ByteList;
			if (byteList == null)
			{
				return given;
			}
			return new object[]
			{
				ARTypeMgr.Instance.toVariant(byteList.Type),
				ARTypeMgr.Instance.toVariant(byteList.Content.Length),
				ARTypeMgr.Instance.toVariant(byteList.Content)
			};
		}
	}
}
